<?php
$server = "localhost";
$uname = "root";
$umm = "root";
$db = "maxik";
$con = mysqli_connect($server, $uname, $umm, $db);
$ll = "select * from admin";
$kaldi = mysqli_query($con, $ll);

$sum="select count(id) from admin where id";
$k_sum=mysqli_query($con, $sum);
$kur_sum = mysqli_fetch_assoc($k_sum);
$kur_sum_pp= implode(',',$kur_sum);


?>

<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport"
          content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<style>
    *{margin: 0;padding: 0 ; text-align: center;font-family: "ALKATIP Basma Tom" ; text-align: center}
    .a{background-color: #dd4444; width: 100%;height: 50px;line-height: 50px;font-size: 30px;
        color: #fff;}
    .form{margin: 50px}
    .button{background-color: #dd4444;padding: 2px;font-size: 30px;margin: 30px; color: #fff;}
    .ll{background-color: #dd4444; width: 100%;height: 50px;line-height: 50px;font-size: 30px}
    .aa{text-align: center;width: 100%;margin-left: 5%}

</style>
<body>
<div class="a">
    تىزىملىتىش بىتى
</div>
<form class="form" action="adminok.php" method="post">
    <input type="hidden" name="id" value="0">
    nami : <input type="text" name="name" placeholder="name">
    password : <input type="password" name="password" placeholder="password">
    <br>
    <button class="button" type="submit"> تىزىملىتىش</button>
    <br>
    <a  href="admin.php" class="ll" >كىرىش بىتى </a>
</form>

<div class="aa">


<table border="1" cellpadding="0" cellspacing="0" align="center">
    <tr>
        <th style="width: 30%">      ئومۇمىي  تىزىملاتقان ئادەم      <?php echo($kur_sum_pp);?><br></th>


    </tr>
</table>
<table border="1" cellpadding="0" cellspacing="0">

    <tr>

        <th style="width: 25%">ئىسمى</th>
        <th style="width: 24%">قوشۇلغان ۋاقتى</th>
        <th style="width: 23%">ئۆزگەرتكەن ۋاقتى</th>
        <th style="width: 25%">ئۆزگەرتىش</th>
        <th style="width: 25%">يۇيۇش</th>
    </tr>

    <?php


    while ($kur = mysqli_fetch_assoc($kaldi)) {
        $id = $kur['id'];
        echo "<tr>";
        echo "<td>" . $kur['isim'] . "</td>";
        echo "<td>" . $kur['insert-time'] . "</td>";
        echo "<td>" . $kur['update-time'] . "</td>";
        echo "<td> <a href='admin.php?id=$id'> 编辑 </a></td>";
        echo "<td> <a href='del.php?id=$id'> 删除 </a></td>";
        echo "</tr> ";

    } mysqli_close($con);





    ?>
</table>
</div>

</body>
</html>